﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace Frame
{
    public class FormHelper
    {
        public static bool SetFormTopMost(Form frm, bool en)
        {
            frm.TopMost = en;
            if (frm.TopMost)
                frm.Focus();
            return frm.TopMost;
        }

        public static bool SetFormTopMost(Form frm)
        {
            frm.TopMost = !frm.TopMost;
            if (frm.TopMost)
                frm.Focus();
            return frm.TopMost;

        }
    }
}
